#ifndef BYTEITEMDELEGATE_H
#define BYTEITEMDELEGATE_H

#include "viewmode.h"

#include <QStyledItemDelegate>


class ByteItemDelegate : public QStyledItemDelegate
{
	Q_OBJECT
public:
	ByteItemDelegate(QObject *parent);
	~ByteItemDelegate();

	virtual void paint(QPainter *painter,
		const QStyleOptionViewItem &option,
		const QModelIndex &index) const;

	virtual QString displayText(const QVariant &value, const QLocale &locale) const;

	ViewMode getViewMode() const;

public slots:
	void setViewMode(ViewMode vm);

private:
	ViewMode _vm;
};

#endif // BYTEITEMDELEGATE_H
